<template>
  <div>
    <h2>父传子</h2>
    <ul>
      <li v-for="(item, i) in list" :key="i">{{ item }}</li>
    </ul>
  </div>
</template>

<script lang="ts">
export default {
  name: "myProp",
};
</script>
<script setup lang="ts">
import { defineProps } from "vue";
defineProps(["list"]);
</script>

<style></style>
